package com.huawei.Galenus.dao;

import com.huawei.Galenus.domain.Song;
import com.huawei.Galenus.domain.Song1;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface SongRepository {

    @Insert("insert into song(id,name,creator,songfilepath,authfilepath) " +
            "values(#{id},#{name},#{creator},#{songfilepath},#{authfilepath})")
    Integer save(Song1 song);

    @Select("select * from song where id=#{id}")
    Song1 selectById(@Param("id") String id);

    @Select("select * from song")
    List<Song1> selectSongs();

}
